<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/html; charset=utf-8" />
<title>登录</title>
<link href="${base}/templates/${config.theme}/front/static/css/passport_login.css" rel="stylesheet" type="text/css" />
<script type="text/javascript" src="${base}/templates/${config.theme}/front/static/js/jquery.js"></script>
<style>
.placeholder {color: #aaa;}
.qrtipsdiv{padding:20px 0 0 140px;height:200px;}
.qrtipsdiv h3 {
    font-size: 16px;
    font-weight: bold;
    line-height: 18px;
    margin-bottom: 24px;
    padding-left: 100px;
}
</style>
</head>
<body>
<div class="layout">
	<div class="header">
		<a href="${base}/" class="logo sprite" id="for-cascade-login-link"></a>
		<div class="bannerHeader sprite"></div>
	</div>
	<div class="content reg clear">
		<div class="regForm loginL">
			<h3>微信关注</h3>
			<p style="text-align:center"><img src="${base}/templates/${config.theme}/front/static/images/qr.jpg"  width="200" /></p>
			<p class="labels" style="text-align:center">关注微信</p>		
		</div>
		<div class="regForm regFormR">
			<form id="inputForm" action="${base}/login" method="post">
            	<h3>登 陆</h3>
				<div class="regHeaderTip">
					如有账号，请登录
				</div>	
				<p class="inputs">
					<input id="username" type="text" class="ipt" name="username" placeholder="手机号码" maxlength="11"/>
				</p>
				<p class="labels" id="usernameTips" style="color: red;"></p>
				<p class="inputs">
					<input id="password" type="password" class="ipt" name="password" placeholder="密码"/>
				</p>
				<p class="labels" id="passwordTips" style="color: red;"></p>
				<p class="mb15">
					<a id="btnLogin" href="javascript:void(0);" class="btn btnLoginDeep">登录</a>
				</p>
				<p class="labels">
					[#if feedback??]
	            		<span style="color: red;">${feedback.content}</span>
	            	[/#if]
				</p>
				<p class="mb50 clear mr70 lh14">
					<span class="fr">
						<a href="${base}/password/forgot" class="f12 coffee">忘记密码?</a>
						<span class="lgray f12">|</span> 
						<a href="${base}/register" class="regLink">免费注册</a>
					</span>
				</p>
			</form>
		</div>
	</div>
</div>
</body>
</html>
 <script type="text/javascript">
 $(document).ready(function() {
	 
	 $("#btnLogin").on("click",function(){
		 $('#inputForm').submit();
	 });
	 
     $('#inputForm').submit(function() {
        var username=$('#username').val();
        if(username.length==0){
            $('#inputForm #usernameTips').html('请输入手机号码！');
            return false;
        }
        if(username.length!=11){
            $('#inputForm #usernameTips').html('请输入有效的手机号码！');
            return false;
        }
        var usernameReg = /^1[3|4|5|8|9|7][0-9]\d{4,8}$/;
        if(!usernameReg.test(username)){
            $('#inputForm #usernameTips').html('请输入有效的手机号码！');
            return false;
        }
        if($('#password').val() == ''){
            $('#inputForm #passwordTips').html('请输入密码！');
            return false;
        }
    }); 
 });
 </script>